<template>
  <!--三级联动全局注册后，这里可以直接使用MainHome，不用再导入-->
  <!--三级分类导航-->
  <MainHome /> 
  <!-- 首页内容 -->
  <MainList />
  <!-- 今日推荐 -->
  <RecommendList />
  <!-- 排行榜 -->
  <RankList />
  <!-- 猜你喜欢 -->
  <LikeList />
  <!-- 楼层分类 -->
  <FloorIndex v-for="(f,index) in floorList" :key="f.id" :floor="f" :index="index" />
   <!-- 品牌分类 -->
   <BrandList />



  <!-- 手机分类 -->
  <!-- <PhoneList /> -->
  <!-- 楼层分类 -->
  <!-- <FloorList /> -->
 
</template>

<script>
import MainList from '@/views/Home/ListContainer/MainList.vue';
import RecommendList from '@/views/Home/TodayRecommend/RecommendList.vue';
import RankList from '@/views/Home/Rank/RankList.vue';
import LikeList from '@/views/Home/Like/LikeList.vue';
// import PhoneList from '@/views/Home/Floor/PhoneList.vue';
// import FloorList from '@/views/Home/Floor/FloorList.vue';
import FloorIndex from '@/views/Home/Floor/FloorIndex.vue';
import BrandList from '@/views/Home/Brand/BrandList.vue';
import { mapState } from 'vuex';


export default {
  name: 'HomeIndex',
  components: {
    MainList,
    RecommendList,
    RankList,
    LikeList,
    FloorIndex,
    // PhoneList,
    // FloorList,
    BrandList
  },
  data() {
    return {

    };
  },
  mounted() {
        this.$store.dispatch("saveFloorList");
    },
    computed: {
       ...mapState({
            floorList: state => state.home.floorList,
        })
    },

  methods: {

  }
};
</script>

<style scoped></style>